package com.huo.thread.waitnotifydemo;

public class Demo1 extends  Thread {

    private WaitNotifyDemo demo;

    public Demo1(WaitNotifyDemo demo) {
        this.demo = demo;
    }

    @Override
    public void run() {
        System.out.println("正在执行：" + demo.getValue());
        demo.setValue(1);
        System.out.println("修改为:" + demo.getValue());

    }
}
